<?php

/**
 * NeoPersonaEvento form.
 *
 * @package    neoTrainner
 * @subpackage form
 * @author     Your name here
 */
class NeoPersonaEventoForm extends BaseNeoPersonaEventoForm {

    public function configure() {
        unset(
                $this['created_at'], $this['updated_at'], $this['apellido']
        );
        
        $this->widgetSchema['neo_persona_id'] = new sfWidgetFormPropelChoice(array('model' => 'NeoPersona', 'add_empty' => false, 'label' => 'Persona'));
        $this->widgetSchema['neo_evento_id'] = new sfWidgetFormPropelChoice(array('model' => 'NeoEvento', 'add_empty' => false, 'label' => 'Evento'));
        $this->widgetSchema['neo_distancia_evento_id'] = new sfWidgetFormPropelChoice(array('model' => 'NeoDistanciaEvento', 'add_empty' => false, 'label' => 'Distancia'));
        $this->widgetSchema['neo_categoria_evento_id'] = new sfWidgetFormPropelChoice(array('model' => 'NeoCategoriaEvento', 'add_empty' => false, 'label' => 'Categoría'));
        
        $this->widgetSchema['estado'] = new sfWidgetFormChoice(array(
                    'choices' => NeoPersonaEventoPeer::$estados,
                    'multiple' => false,
                    'default' => NeoPersonaEventoPeer::ESTADO_PRE_INSCRIPTO,
                    'expanded' => false
                ));
        $this->validatorSchema['acepta_terminos'] = new sfValidatorBoolean(
                        array('required' => true),
                        array('required' => 'Condición obligatoria para inscribirse.')
        );
        
    }

}
